package com.qf.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.qf.mapper.DtsGoodsProductMapper;
import com.qf.pojo.DtsGoodsProduct;
import com.qf.service.DtsProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @version v1.0.0
 * @Description:
 * @author: 姜红凯
 * @date: 2022.02.21
 * @since 1.0
 */
@Service
public class DtsProductServiceImpl implements DtsProductService {

    @Autowired
    DtsGoodsProductMapper goodsProductMapper;

    @Override
    public int queryTotal() {
        LambdaQueryWrapper<DtsGoodsProduct> wrapper = new LambdaQueryWrapper<>();
        wrapper.eq(DtsGoodsProduct::getDeleted,false);

        Integer count = goodsProductMapper.selectCount(wrapper);

        return count;
    }
}
